2.1 Information and Information Transmission

|

11

t

fundamental wave (1st harmonic)

first overtone (2nd harmonic)

second overtone (3rd harmonic)

time t/s

frequency f/Hz

Fig. 2.4: Bandlimited pulse width modulation signal from Figure 2.3 with associated spectrum.

The coefficients ak, bk in Equation 2.9 indicate the real amplitudes of the individual

sine and cosine harmonics of the k-th harmonics. For band-limited signals k is limited

by a value K, kK <; they are also numerically only defined on the basis of this.

Listing 2.1: Matlab example for generating different modulation signals.

Am1 = 0.35; fm1 = 0.05;

% amplitudes and frequencies

Am2 = 0.25; fm2 = 0.1;

% of the harmonic

Ac = 1; fc = 1;

N=10; fs=N*fc;

% sampling frequency

t = 0:1/fs:0.25/fm1;

% time vector low fs (discrete)

th = 0:1/fs/10:0.25/fm1;

% time vector high fs (cont.)

% Information signal

is = 0.3 + Am1*cos(2*pi*fm1.*t) + Am2*cos(2*pi*fm2.*t);

ish =

0.3 + Am1*cos(2*pi*fm1.*th) + Am2*cos(2*pi*fm2.*th);

subplot(7,1,1)

% subplot for 7 plots among each other

stem(t,is)

% discrete representation

hold on

plot(th,ish)

% continuous representation

% Carrier signal

cs = Ac*cos(2*pi*fc.*t);

csh = Ac*cos(2*pi*fc.*th);

subplot(7,1,2)

stem(t,cs)

% discrete representation